<?php

namespace app\admin\model;

use app\common\model\Base;

class Config extends Base {
  protected $name = 'config';
  protected $auto = ['creator_uid'];

  public function setCreatorUidAttr($value) {
    return session('user_id');
  }

  public function initialize() {
    parent::initialize();
  }

  public function getNewest(){
    return self::order('id DESC')->find();
  }
}